<template>
  <div>
    <el-card>
      <div slot="header" class="clearfix">
        <span>取值</span>
      </div>
      <div>
        <div>年:{{date | date_year('年')}}</div>
        <div>月:{{date | date_month('月')}}</div>
        <div>日:{{date | date_date}}</div>
        <div>时:{{date | date_hour}}</div>
        <div>分:{{date | date_minute}}</div>
        <div>秒:{{date | date_second}}</div>
      </div>
    </el-card>
    <el-card>
      <div slot="header" class="clearfix">
        <span>格式化</span>
        
      </div>
      <div>
        <div>年:{{date | date_format}}</div>
        <div>年:{{date1 | date_format_start}}</div>
        <div>年:{{date2 | date_format_start}}</div>
      </div>
    </el-card>
  </div>
</template>

<script>
export default {
  name: "ExampleFiltersDate",
  data() {
    let date = new Date();
    return {
      date,
      date1 : 1546790400000 , //2019-01-07 00:00:00
      date2 : 1546876800000 , //2019-01-08 00:00:00
    };
  }
};
</script>

<style scoped lang="scss">
</style>
